<div class="main-wrap">

        <div class="crumb-wrap">
            <div class="crumb-list"><i class="icon-font"></i><a href="index.html">首页</a><span class="crumb-step">&gt;</span><span class="crumb-name">作品管理</span></div>
        </div>
        <div class="search-wrap">
            <div class="search-content">
                <form action="" method="post">
                    <table class="search-tab">
                        <tr>
                            
                            <th width="70">qq号:</th>
                            <td><input class="common-text" placeholder="关键字" name="kefu" value="" id="" type="text"></td>
                            <td><input class="btn btn-primary btn2" name="sub" value="添加客服" type="submit"></td>
							<td>多客服情况下客服随机展示</td>
                        </tr>
                    </table>
                </form>
            </div>
        </div>
        <div class="result-wrap">
            <form name="myform" id="myform" method="post">
              
                <div class="result-content">
                    <table class="result-tab" width="100%">
                        <tr>
                            
                            <th>QQ号</th>
                            <th>操作</th>
                        </tr>
						
						<foreach name="re" item="v">
						
                        <tr>
                             
                            <td>
                               QQ号： {$v.kefu}
                            </td>
                          
                            <td>
                               
                                <a class="link-del" style="cursor:pointer;" onclick="del({$v.id})">删除</a>
                            </td>
                        </tr>
                       
					   </foreach>
					   
                    </table>
                    
                </div>
            </form>
        </div>
    </div>
	
	<script>
	  
	  function del(i){
	  
	     if(confirm('您确定删除吗')){
		 
		    $.post('{:U("Kefu/del")}',{"id":i},function(re){
			
			  if(re==1){
			  
			    alert('删除成功');location.reload();
			  
			  }else{
			  
			    alert('删除失败');
			  
			  }
			
			})
		 
		 }
	    
	  }
	
	</script>
	
	
